package daily.apr0430;

import java.io.IOException;

public class RuntimeTest {
    public static void main(String[] args) throws IOException {
        Runtime runtime = Runtime.getRuntime();
//        Process process = runtime.exec("notepad.exe");
        System.out.println("Java虚拟机中的空闲内存量:" + runtime.freeMemory() / 1024 / 2014 + "MB");
        System.out.println("Java虚拟机试图使用的最大内存量:" + runtime.maxMemory() / 1024 / 2014 + "MB");
        System.out.println("Java虚拟机中的内存总量:" + runtime.totalMemory() / 1024 / 2014 + "MB");
    }
}
